//  re
#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int n = s.size();
  s = '?' + s;
  int l = 1, r = 2;
  while (true) {
    while (l < n && s[l] != '#') {
      l++;
    }
    r = l + 1;
    while (r <= n && s[r] != '#') {
      r++;
    }
    if (!(l < n && r <= n))
      break;
    cout << l << "," << r << endl;
    l = r + 1;
    r = l + 1;
  }

  return 0;
}